#include <bits/stdc++.h>
using namespace std;

typedef long long LL;

const int N = 3e5+50;

int n, a[N];

int num[2];

int main(int argc, char const *argv[])
{
    int n1 = 0, n2 = 0;
    scanf("%d", &n);
    LL ans = 0;
    for (int i=0; i<n; ++i) {
        scanf("%d", &a[i]);
        ans += a[i] / 2;
        if (a[i] & 1)
        {
            num[i & 1]++;
        }
    }
    ans += min(num[0], num[1]);
    printf("%lld\n", ans);
    
    return 0;
}
